//
//  ApplicationModel.swift
//  GitTFGUI
//
//  Created by Samuel Richard Magny on 2015-09-26.
//  Copyright © 2015 Samuel Richard Magny. All rights reserved.
//

import Cocoa
import TFSClient

class ApplicationModel: NSObject {

    let notificationCenter:TFSClientNotificationCenter
    
    let tfsClient:ExtendedTFSClient
    let userSettings: UserSettings
    let externalCommitController:ExternalCommitController
    
    static let DefaultApplicationModel = ApplicationModel()
    
    
    override init() {
        userSettings = UserSettings.defaultUserSettings
        notificationCenter = TFSClientNotificationCenter()
        externalCommitController = ExternalCommitController(userSettings: userSettings)
        
        tfsClient = ExtendedTFSClient(userSettings: userSettings, broadcastCenter:notificationCenter)
        
        super.init()
    }
    
    
    func isCurrentWorkingDirectoryValid() -> Bool {
        
        return tfsClient.isCurrentWorkingDirectoryValid()
    }
    
    
    

    

    
}
